﻿using Common.Data.Repository;
using SalePerformance.Core.Data.DataContextStorage;
using SalePerformance.Model.Model;
using System.Data.Entity;

namespace SalePerformance.Core.Data.Repository
{
    public class SalePerformanceRepository : GenericRepository
    {
        public SalePerformanceRepository()
            : base(DataContextFactory.GetDataContext())
        {
        }

        private static SalePerformanceRepository _current = null;
        public static SalePerformanceRepository Current
        {
            get
            {
                return new SalePerformanceRepository();
            }
        }
        public DbSet<TblSpDepositEop> DepositEOP
        {
            get
            {
                return ((SalePerformanceEntities)this.DbContext).DepositEOP;
            }
        }

        public DbSet<TblSpLoanEop> LoanEOP
        {
            get
            {
                return ((SalePerformanceEntities)this.DbContext).LoanEOP;
            }
        }

        public DbSet<TblHuntingCustomer> HuntingCustomers
        {
            get
            {
                return ((SalePerformanceEntities)this.DbContext).HuntingCustomers;
            }
        }
        public DbSet<TblSpCashManagementEop> TblSpCashManagementEops
        {
            get
            {
                return ((SalePerformanceEntities)this.DbContext).CashManagementEops;
            }
        }
        public DbSet<TblSpTradeEop> TblSpTradeEops
        {
            get
            {
                return ((SalePerformanceEntities)this.DbContext).TradeEops;
            }
        }
        public DbSet<TblSalePerformanceKpi> SaleKPIs
        {
            get
            {
                return ((SalePerformanceEntities)this.DbContext).SaleKPIs;
            }
        }
        public DbSet<TblKpiRankBranch> KpiRankBranchs
        {
            get
            {
                return ((SalePerformanceEntities)this.DbContext).KpiRankBranchs;
            }
        }
        public DbSet<TblKpiRawDnbqDaily> KpiRawDnbqDailys
        {
            get
            {
                return ((SalePerformanceEntities)this.DbContext).KpiRawDnbqDailys;
            }
        }
        public DbSet<TblKpiRawCardDaily> KpiRawCardDailys 
        {
            get
            {
                return ((SalePerformanceEntities)this.DbContext).KpiRawCardDailys;
            }
        }
        public DbSet<TblSaleContestBilawardRankingDaily> BilawardBranchRankingDailys
        {
            get
            {
                return ((SalePerformanceEntities)this.DbContext).BilawardBranchRankingDailys;
            }
        }
        public DbSet<TblSaleContestBilAwardRaw> SaleContestBilAwardRaws
        {
            get
            {
                return ((SalePerformanceEntities)this.DbContext).SaleContestBilAwardRaws;
            }
        }
        public DbSet<TblKpiRawKhhdDaily> KpiRawKhhdDailys
        {
            get
            {
                return ((SalePerformanceEntities)this.DbContext).KpiRawKhhdDailys;
            }
        }
        public DbSet<TblKpiMsboRaw> KpiMsboRawDailys
        {
            get
            {
                return ((SalePerformanceEntities)this.DbContext).KpiMsboRawDailys;
            }
        }
    }
}
